{% set data =  hostvars | get_check_data    %}
生成时间：{{ data.time }}
Error Total: {{ data.summary.error }}
Critical Total: {{ data.summary.critical }}
Bad Total: {{ data.summary.bad }}
OK Total: {{ data.summary.ok }}
Total: {{ data.summary.total }}

{# 错误项处理：假设 data.error_item 是字典 #}
{% if data.summary.error != 0 %}
  {% for key, value in data.error_item.items() %}
    {{ key }}-{{ value }}
  {% endfor %}
{% endif %}

{# 正常项处理：假设 data.ok_item 是嵌套字典 #}
{% if data.summary.ok != 0 %}
  {% for key, details in data.ok_item.items() %}
  {{ details }}

  {% endfor %}
{% endif %}